package com.roc.template.exception;

/**
 * @ClassName BaseException
 * @Description: TODO
 * @Author Administrator
 * @Date 2020/7/28 15 42
 * @Version V1.0
 **/
public class BaseException extends RuntimeException {

    private String errorCode = "";

    private Object data ;

    public String getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }

    public BaseException() {
    }

    public BaseException(String error, String errorCode) {
        super(error);
        this.errorCode = errorCode;
    }

    public BaseException(String error, String errorCode, Object data) {
        super(error);
        this.errorCode = errorCode;
        this.data = data;
    }

    public BaseException(String error) {
        super(error);
    }

    public BaseException(String error, Throwable cause) {
        super(error, cause);
    }

    public BaseException(Throwable cause) {
        super(cause);
    }

    public BaseException(String error, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
        super(error, cause, enableSuppression, writableStackTrace);
    }

}
